<template>
	<view class="content">
		<uni-segmented-control :current="current" :values="list" @clickItem="onClickItem" styleType="text"
			activeColor="#ff557f"></uni-segmented-control>
		<view>
			<view v-show="current === 0" class="tab">
				<view class="info">
					<view class="">
						<text>成熟度:&nbsp&nbsp&nbsp{{maturity ||'很熟'}}</text>
					</view>
					<view class="">
						<text>优点:&nbsp&nbsp&nbsp{{flaw || "保存时间长"}}</text>
					</view>
				</view>
				<view class="info">
					<view class="">
						<text>支长:&nbsp&nbsp&nbsp50cm</text>
					</view>
					<view class="">
						<text>瑕疵:&nbsp&nbsp&nbsp无需说明</text>
					</view>
				</view>
			</view>
			<view v-show="current === 1" class="tab">
				暂无评论
			</view>

		</view>
	</view>
</template>

<script>
	export default {
		name: "table_info",
		data() {
			return {
				current: 0,
				list: ['商品详情', '评价']
			};
		},
		props: {
			maturity: {
				type:String,
			},
			flaw:String
		},
		methods: {
			onClickItem(e) {
				this.current = e.currentIndex;
			}
		}
	}
</script>

<style scoped>
	.content {
		width: 100%;
		height: 200rpx;
		background-color: #FFFFFF;
		border-top: 20rpx solid #efefef;
		/* padding-bottom: 200rpx; */
	}

	.tab {
		padding-left: 20rpx;
	}

	.info {
		display: flex;
		margin-top: 10rpx;
	}

	.info view {
		flex: 1;
	}
</style>
